<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Habbit App</title>
    <link rel="stylesheet" href="./styles/main.css" />
  </head>
  <body>
    <div class="app">
      <div class="panel">
        <img
          class="logo"
          src="./images/logo.svg"
          alt="Лого Habbit App"
          srcset=""
        />
        <nav class="menu">
          <div class="menu__list"></div>
          <button class="menu__add" onclick="togglePopup()">
            <img src="./images/add.svg" alt="Добавить привычку" srcset="" />
          </button>
        </nav>
      </div>
      <div class="content">
        <header>
          <h1 class="h1">-</h1>
          <div class="progress">
            <div class="progress__text">
              <div class="progress__name">Прогресс</div>
              <div class="progress__percent">%</div>
            </div>
            <div class="progress__bar">
              <div class="progress__cover-bar"></div>
            </div>
          </div>
        </header>
        <main>
          <div id="days"></div>
          <div class="habbit">
            <div class="habbit__day">День _</div>
            <form class="habbit__form" onsubmit="addDays(event)">
              <img
                class="input__icon"
                src="./images/comment.svg"
                alt="Иконка комментацрия"
                srcset=""
              />
              <input
                name="comment"
                type="text"
                class="input_icon"
                placeholder="Комментарий"
              />
              <button class="button" type="submit">Готово</button>
            </form>
          </div>
        </main>
      </div>
      <div class="cover cover_hidden" id="add-habbit-popup">
        ;
        <div class="popup">
          <h2>Новая привычка</h2>
          <div class="icon-label">Иконка</div>
          <div class="icon-select">
            <button class="icon icon_active" onclick="setIcon(this, 'sport')">
              <img src="./images/sport.svg" alt="Спорт" />
            </button>
            <button class="icon" onclick="setIcon(this, 'water')">
              <img src="./images/water.svg" alt="Напитки" />
            </button>
            <button class="icon" onclick="setIcon(this, 'food')">
              <img src="./images/food.svg" alt="Еда" />
            </button>
          </div>
          <form action="" class="popup__form" onsubmit="addHabbits(event)">
            <input type="text" name="name" placeholder="Название" />
            <input
              type="text"
              name="icon"
              hidden
              placeholder="Название"
              value="sport"
            />
            <input type="number" name="target" placeholder="Цель" />
            <button class="button" type="submit" >Добавить</button>
            <button class="popup__close" onclick="togglePopup()">
              <img src="./images/close.svg" alt=" Закрыть" />
            </button>
          </form>
        </div>
      </div>
    </div>

    <script src="./scripts/app.js"></script>
  </body>
</html>
